Skip to content

chore(parser): deprecate AlbMultiValueHeadersSchema #3523

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 24, 2025

Conversation

dreamorosi
Copy link
Contributor

Summary

Changes

Please provide a summary of what's being changed

This PR marks as deprecated the AlbMultiValueHeadersSchema and standardizes the tests for this category of schema.

The AlbMultiValueHeadersSchema is marked as deprecated to standardize with the Python version of Powertools for AWS Lambda (Python). For ALB the single-value version of headers and queryStringParameters and the multi-value ones are mutually exclusive, so we can just aggregate the four properties in the regular AlbSchema and mark them all as .optional() to achieve the same result.

This reduces the cognitive load for customers and avoids them having to use two different schemas if they have different ALB configurations handled by functions sharing the same code.

Additionally the PR refactors and standardizes the Parser helpers tests.

Please add the issue number below, if no issue is present the PR might get blocked and not be reviewed

Issue number: closes #3522


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@dreamorosi dreamorosi self-assigned this Jan 24, 2025
@dreamorosi dreamorosi requested a review from a team January 24, 2025 00:01
@dreamorosi dreamorosi requested a review from a team as a code owner January 24, 2025 00:01
@boring-cyborg boring-cyborg bot added parser This item relates to the Parser Utility tests PRs that add or change tests labels Jan 24, 2025
@pull-request-size pull-request-size bot added the size/L PRs between 100-499 LOC label Jan 24, 2025
@dreamorosi dreamorosi merged commit 5bb4a6a into main Jan 24, 2025
46 checks passed
@dreamorosi dreamorosi deleted the chore/parser_alb branch January 24, 2025 09:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
parser This item relates to the Parser Utility size/L PRs between 100-499 LOC tests PRs that add or change tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Maintenance: deprecate AlbMultiValueHeadersSchema in favor of AlbSchema for Parser
2 participants